package com.example.demo;

public class News {
    /**
     * 私有变量声明
     */
    private String title;// 新闻标题
    private String content;// 新闻内容

    /**
     * 构造函数
     * @param title
     * @param content
     */
    public News(String title, String content) {
        this.title = title;
        this.content = content;
    }

    /**
     * Getter、Setter
     * @return
     */
    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }
}